﻿namespace ActivateYourGlutes.Services.Model
{
    public class UserLocaleSettings
    {
        public string DateFormat { get; set; }

        public string DateTimeFormat
        {
            get { return string.Concat(DateFormat, " hh:mm:ss"); }
        }

        public string JQueryDateFormat
        {
            get
            {
                // This is vile. The date formats for jQuery and C# are different. Just lovely. Thankfully we only expose two.
                if (DateFormat == "dd-MM-yyyy")
                    return "dd-mm-yy";
                return "mm-dd-yy";
            }
        }

        public UnitOfLength UnitOfLength { get; set; }

        public UnitOfWeight UnitOfWeight { get; set; }
    }
}